<!DOCTYPE html>
<html>

<head lang="en">
  <meta charset="UTF-8">
  <title></title>
  <style type="text/css">
    * {
      margin: 0;
      padding: 0;
    }

    ul {
      list-style: none;
    }

    .wrap {
      width: 330px;
      height: 30px;
      margin: 200px auto 0;
      padding-left: 10px;
      background-image: url(imgs/bg.jpg);
    }

    .wrap li {
      background-image: url(imgs/libg.jpg);
    }

    .wrap>ul>li {
      float: left;
      position: relative;
      margin-right: 10px;
    }

    .wrap a {
      display: block;
      height: 30px;
      width: 100px;
      text-align: center;
      line-height: 30px;
      text-decoration: none;
      color: #000;
    }

    .wrap li ul {
      position: absolute;
      top: 30px;
      display: none;
    }
  </style>
</head>

<body>
  <div class="wrap">
    <ul>
      <li>
        <a href="javascript:void(0);">一级菜单1</a>
        <ul class="ul">
          <li><a href="javascript:void(0);">二级菜单1</a></li>
          <li><a href="javascript:void(0);">二级菜单2</a></li>
          <li><a href="javascript:void(0);">二级菜单3</a></li>
        </ul>
      </li>
      <li>
        <a href="javascript:void(0);">一级菜单2</a>
        <ul>
          <li><a href="javascript:void(0);">二级菜单1</a></li>
          <li><a href="javascript:void(0);">二级菜单2</a></li>
          <li><a href="javascript:void(0);">二级菜单3</a></li>
        </ul>
      </li>
      <li>
        <a href="javascript:void(0);">一级菜单3</a>
        <ul>
          <li><a href="javascript:void(0);">二级菜单1</a></li>
          <li><a href="javascript:void(0);">二级菜单2</a></li>
          <li><a href="javascript:void(0);">二级菜单3</a></li>
        </ul>
      </li>
    </ul>
  </div>

  <script src="../jquery/jquery.min.js"></script>
  <script>
    $('.wrap>ul>li>a').hover(function () {
      $(this).next().stop().slideDown();
    }, function () {
      $(this).next().stop().slideUp();
    });
  </script>
</body>

</html>